#include <iostream>
using namespace std;

const int kMaxN = 1e7 + 10;
int fac[kMaxN];
int pri[kMaxN / 10], tot = 0;

void GetPrimeList() {
  for (int i = 2; i < kMaxN; i++) {
    if (fac[i] == 0) {
      fac[i] = i;
      pri[tot++] = i;
    }
    for (int j = 0; j < tot && i * pri[j] < kMaxN; j++) {
      fac[i * pri[j]] = pri[j];
      if (i % pri[j] == 0) {
        break;
      }
    }
  }
}

int GetAns(int n) {
  int ret = 1;

  for (; n > 1;) {
    int cnt = 1, p = fac[n];

    for (; fac[n] == p; n /= p, cnt++);
    ret *= cnt;
  }

  return ret;
}

int main() {
  ios::sync_with_stdio(0), cin.tie(0), cout.tie(0);
  int T;

  GetPrimeList();
  for (cin >> T; T; T--) {
    int n;

    cin >> n;
    cout << GetAns(n) << "\n";
  }
  return 0;
}